.class Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;
.super Landroid/webkit/WebViewClient;
.source "RedirectClickListener.java"

# interfaces
.implements Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;
.implements Ljava/lang/Runnable;


# static fields
.field private static final CLICKABLE_DELAY:I = 0xbb8


# instance fields
.field private final mClickHandler:Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectAwareClickHandler;

.field private volatile mClickable:Z

.field private mOriginalListener:Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;

.field private final mService:Ljava/util/concurrent/ScheduledExecutorService;

.field private final mUrlProvider:Lcom/burstly/lib/component/networkcomponent/burstly/html/UrlProvider;


# direct methods
.method constructor <init>(Lcom/burstly/lib/component/AbstractAdaptor$AdaptorListenerWrapper;Ljava/lang/String;ZLcom/burstly/lib/component/networkcomponent/burstly/html/UrlProvider;)V
    .locals 1
    .parameter "listener"
    .parameter "networkName"
    .parameter "isFullscreen"
    .parameter "urlProvider"

    .prologue
    .line 75
    invoke-direct {p0}, Landroid/webkit/WebViewClient;-><init>()V

    .line 54
    invoke-static {}, Ljava/util/concurrent/Executors;->newSingleThreadScheduledExecutor()Ljava/util/concurrent/ScheduledExecutorService;

    move-result-object v0

    iput-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mService:Ljava/util/concurrent/ScheduledExecutorService;

    .line 64
    const/4 v0, 0x1

    iput-boolean v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mClickable:Z

    .line 76
    new-instance v0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectAwareClickHandler;

    invoke-direct {v0, p1, p2, p3}, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectAwareClickHandler;-><init>(Lcom/burstly/lib/component/AbstractAdaptor$AdaptorListenerWrapper;Ljava/lang/String;Z)V

    iput-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mClickHandler:Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectAwareClickHandler;

    .line 77
    iput-object p4, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mUrlProvider:Lcom/burstly/lib/component/networkcomponent/burstly/html/UrlProvider;

    .line 78
    return-void
.end method

.method private doClick(Ljava/lang/String;)V
    .locals 1
    .parameter "url"

    .prologue
    .line 101
    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mUrlProvider:Lcom/burstly/lib/component/networkcomponent/burstly/html/UrlProvider;

    invoke-virtual {v0, p1}, Lcom/burstly/lib/component/networkcomponent/burstly/html/UrlProvider;->setUrl(Ljava/lang/String;)V

    .line 102
    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mClickHandler:Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectAwareClickHandler;

    invoke-virtual {v0, p1}, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectAwareClickHandler;->click(Ljava/lang/String;)V

    .line 103
    return-void
.end method


# virtual methods
.method getAdaptorListener()Lcom/burstly/lib/component/IBurstlyAdaptorListener;
    .locals 1

    .prologue
    .line 120
    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mClickHandler:Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectAwareClickHandler;

    invoke-virtual {v0}, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectAwareClickHandler;->getListener()Lcom/burstly/lib/component/AbstractAdaptor$AdaptorListenerWrapper;

    move-result-object v0

    return-object v0
.end method

.method getNetworkName()Ljava/lang/String;
    .locals 1

    .prologue
    .line 111
    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mClickHandler:Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectAwareClickHandler;

    invoke-virtual {v0}, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectAwareClickHandler;->getNetworkName()Ljava/lang/String;

    move-result-object v0

    return-object v0
.end method

.method public getRichMediaListener()Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;
    .locals 1

    .prologue
    .line 204
    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mOriginalListener:Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;

    return-object v0
.end method

.method public handleRequest(Ljava/lang/String;)V
    .locals 1
    .parameter "url"

    .prologue
    .line 179
    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mOriginalListener:Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;

    if-eqz v0, :cond_0

    .line 180
    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mOriginalListener:Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;

    invoke-interface {v0, p1}, Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;->handleRequest(Ljava/lang/String;)V

    .line 182
    :cond_0
    return-void
.end method

.method isFullscreen()Z
    .locals 1

    .prologue
    .line 129
    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mClickHandler:Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectAwareClickHandler;

    invoke-virtual {v0}, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectAwareClickHandler;->isFullscreen()Z

    move-result v0

    return v0
.end method

.method public onClick(Ljava/lang/String;)V
    .locals 1
    .parameter "url"

    .prologue
    .line 134
    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mOriginalListener:Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;

    if-eqz v0, :cond_0

    .line 135
    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mOriginalListener:Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;

    invoke-interface {v0, p1}, Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;->onClick(Ljava/lang/String;)V

    .line 137
    :cond_0
    invoke-direct {p0, p1}, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->doClick(Ljava/lang/String;)V

    .line 138
    return-void
.end method

.method public onEventFired()Z
    .locals 1

    .prologue
    .line 167
    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mOriginalListener:Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;

    if-eqz v0, :cond_0

    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mOriginalListener:Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;

    invoke-interface {v0}, Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;->onEventFired()Z

    move-result v0

    if-eqz v0, :cond_0

    const/4 v0, 0x1

    :goto_0
    return v0

    :cond_0
    const/4 v0, 0x0

    goto :goto_0
.end method

.method public onExpand()Z
    .locals 1

    .prologue
    .line 152
    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mOriginalListener:Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;

    if-eqz v0, :cond_0

    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mOriginalListener:Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;

    invoke-interface {v0}, Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;->onExpand()Z

    move-result v0

    if-eqz v0, :cond_0

    const/4 v0, 0x1

    :goto_0
    return v0

    :cond_0
    const/4 v0, 0x0

    goto :goto_0
.end method

.method public onExpandClose()Z
    .locals 1

    .prologue
    .line 157
    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mOriginalListener:Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;

    if-eqz v0, :cond_0

    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mOriginalListener:Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;

    invoke-interface {v0}, Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;->onExpandClose()Z

    move-result v0

    if-eqz v0, :cond_0

    const/4 v0, 0x1

    :goto_0
    return v0

    :cond_0
    const/4 v0, 0x0

    goto :goto_0
.end method

.method public onHide()V
    .locals 1

    .prologue
    .line 186
    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mOriginalListener:Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;

    if-eqz v0, :cond_0

    .line 187
    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mOriginalListener:Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;

    invoke-interface {v0}, Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;->onHide()V

    .line 189
    :cond_0
    return-void
.end method

.method public onPageFinished(Landroid/webkit/WebView;Ljava/lang/String;)V
    .locals 0
    .parameter "view"
    .parameter "url"

    .prologue
    .line 82
    invoke-super {p0, p1, p2}, Landroid/webkit/WebViewClient;->onPageFinished(Landroid/webkit/WebView;Ljava/lang/String;)V

    .line 84
    return-void
.end method

.method public onReady()Z
    .locals 1

    .prologue
    .line 142
    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mOriginalListener:Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;

    if-eqz v0, :cond_0

    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mOriginalListener:Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;

    invoke-interface {v0}, Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;->onReady()Z

    move-result v0

    if-eqz v0, :cond_0

    const/4 v0, 0x1

    :goto_0
    return v0

    :cond_0
    const/4 v0, 0x0

    goto :goto_0
.end method

.method public onResize()Z
    .locals 1

    .prologue
    .line 147
    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mOriginalListener:Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;

    if-eqz v0, :cond_0

    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mOriginalListener:Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;

    invoke-interface {v0}, Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;->onResize()Z

    move-result v0

    if-eqz v0, :cond_0

    const/4 v0, 0x1

    :goto_0
    return v0

    :cond_0
    const/4 v0, 0x0

    goto :goto_0
.end method

.method public onResizeClose()Z
    .locals 1

    .prologue
    .line 162
    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mOriginalListener:Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;

    if-eqz v0, :cond_0

    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mOriginalListener:Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;

    invoke-interface {v0}, Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;->onResizeClose()Z

    move-result v0

    if-eqz v0, :cond_0

    const/4 v0, 0x1

    :goto_0
    return v0

    :cond_0
    const/4 v0, 0x0

    goto :goto_0
.end method

.method public onShow()V
    .locals 1

    .prologue
    .line 193
    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mOriginalListener:Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;

    if-eqz v0, :cond_0

    .line 194
    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mOriginalListener:Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;

    invoke-interface {v0}, Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;->onShow()V

    .line 196
    :cond_0
    return-void
.end method

.method public onTouchEvent()V
    .locals 1

    .prologue
    .line 172
    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mOriginalListener:Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;

    if-eqz v0, :cond_0

    .line 173
    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mOriginalListener:Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;

    invoke-interface {v0}, Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;->onTouchEvent()V

    .line 175
    :cond_0
    return-void
.end method

.method public run()V
    .locals 1

    .prologue
    .line 225
    const/4 v0, 0x1

    iput-boolean v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mClickable:Z

    .line 226
    return-void
.end method

.method public setRichMediaListener(Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;)V
    .locals 0
    .parameter "originalListener"

    .prologue
    .line 213
    iput-object p1, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mOriginalListener:Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;

    .line 214
    return-void
.end method

.method public setStatisticsSender(Lcom/burstly/lib/component/networkcomponent/burstly/html/StatisticsSender;)V
    .locals 1
    .parameter "statisticsSender"

    .prologue
    .line 218
    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mOriginalListener:Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;

    if-eqz v0, :cond_0

    .line 219
    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mOriginalListener:Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;

    invoke-interface {v0, p1}, Lcom/burstly/lib/component/networkcomponent/burstly/html/IRichMediaAdListener;->setStatisticsSender(Lcom/burstly/lib/component/networkcomponent/burstly/html/StatisticsSender;)V

    .line 221
    :cond_0
    return-void
.end method

.method public shouldOverrideUrlLoading(Landroid/webkit/WebView;Ljava/lang/String;)Z
    .locals 4
    .parameter "view"
    .parameter "url"

    .prologue
    .line 88
    iget-boolean v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mClickable:Z

    if-eqz v0, :cond_0

    .line 89
    invoke-direct {p0, p2}, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->doClick(Ljava/lang/String;)V

    .line 90
    const/4 v0, 0x0

    iput-boolean v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mClickable:Z

    .line 91
    iget-object v0, p0, Lcom/burstly/lib/component/networkcomponent/burstly/html/RedirectClickListener;->mService:Ljava/util/concurrent/ScheduledExecutorService;

    const-wide/16 v1, 0xbb8

    sget-object v3, Ljava/util/concurrent/TimeUnit;->MILLISECONDS:Ljava/util/concurrent/TimeUnit;

    invoke-interface {v0, p0, v1, v2, v3}, Ljava/util/concurrent/ScheduledExecutorService;->schedule(Ljava/lang/Runnable;JLjava/util/concurrent/TimeUnit;)Ljava/util/concurrent/ScheduledFuture;

    .line 94
    :cond_0
    const/4 v0, 0x1

    return v0
.end method
